package cate.common.table.activity.wishblessing.sheet;

import cate.common.table.ESheet;
import cate.common.table.activity.wishblessing.row.WishBlessingBaseRow;

import java.util.List;
import java.util.stream.Collectors;

public class WishBlessingBaseSheet extends ESheet<WishBlessingBaseRow> {
    @Override
    public String getSheetName() {
        return "禁用英雄";
    }

    public WishBlessingBaseRow getBaseRow(int configId, byte camp) {
        return getList().stream().filter(e -> e.configId == configId && e.camp == camp).findAny().orElse(null);
    }

    public List<WishBlessingBaseRow> getAllBaseRows(int configId) {
        return getList().stream().filter(e -> e.configId == configId).collect(Collectors.toList());
    }
}
